Route display method and related apparatus

ABSTRACT

This application provides a route display method performed by a computer device. When a route planning request for a route planning mode is obtained from a terminal device, a corresponding route planning result and original interpretation data involved in the current route planning result are determined; a route interpretation scenario corresponding to the original interpretation data and the route planning mode are used to query a corresponding target interpretation template; and a target interpretation element that needs to be displayed when the route planning result is displayed in an electronic map on the terminal device is determined through the target interpretation template, to explain the route planning result by using the target interpretation element. Such a manner of interpreting templates can store, query, modify and synchronize the interpretation templates through a database, so that combinations of various route planning modes and route interpretation scenarios can be decoupled from each other.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation application of PCT Patent ApplicationNo. PCT/CN2021/122536, entitled “PATH DISPLAY METHOD AND RELATEDAPPARATUS” filed on Oct. 8, 2021, which claims priority to ChinesePatent Application No. 202011189857.4, filed with the State IntellectualProperty Office of the People's Republic of China on Oct. 30, 2020, andentitled “ROUTE DISPLAY METHOD AND RELATED APPARATUS”, all of which areincorporated herein by reference in their entirety.

FIELD OF THE TECHNOLOGY

This application relates to the field of electronic maps, and inparticular, to a route display technology in the electronic maps.

BACKGROUND OF THE APPLICATION

Route planning is a basis of electronic map navigation and is also oneof the most important core functions in an electronic map. Routeplanning is generally defined as finding one or more routes from adesignated starting point to a designated end point. In addition toperforming route planning on a homepage of the map, a new route planningrequest will be triggered in various route planning modes such asyawing, main and side road switching, user preference changing, and viapoint adding or removing in navigation. When a route planning resultcalculated in response to the route planning request is obtained, theroute planning result may be displayed through the electronic map.

When the route planning result is displayed, the route planning resultneeds to be explained correspondingly to answer a user's possibleconfusion about the current route planning result, for example, “Why isa familiar route not recommended this time?”, “Why is the routerecommended this time a bit detoured?” and other questions. That is,when the route planning result is displayed, a reason for recommendingthe route planning result is displayed correspondingly to eliminate userconfusion.

With the development of electronic maps, the foregoing routeinterpretation scenarios are becoming more and more abundant, forexample, road restrictions, avoiding road closures, or the like. Inaddition, newly added route interpretation scenarios also need to becompatible with different route planning modes, which will cause a largenumber of combinations of route interpretation scenarios and routeplanning modes to be newly added.

In the related art, to implement the route interpretation scenarios inthe electronic map, a hard-coding manner is needed, that is, every timea route interpretation scenario is newly added, a server and a terminaldevice need to update protocol data based on the newly added routeinterpretation scenario and a large number of related combinations. Notonly code logic is complex, but a version cannot be released until eachimplements internal logic iteration, and overall iteration efficiency isvery low.

SUMMARY

To resolve the foregoing technical problems, this application provides aroute display method and a related apparatus, which can simplify codelogic and improve iteration efficiency.

Embodiments of this application disclose the following technicalsolutions:

according to a first aspect, an embodiment of this application providesa route display method, performed by a server, the method including:

determining a corresponding route planning result and originalinterpretation data according to a route planning request for a routeplanning mode, the route planning mode being used for identifying areason for initiating the route planning request;

determining a corresponding target interpretation template according tothe route planning mode and a route interpretation scenariocorresponding to the original interpretation data;

determining element information according to the original interpretationdata and the target interpretation template, the element informationincluding an element identifier of a target interpretation elementcorresponding to the route planning result; and transmitting the elementinformation to the terminal device, the element identifier in theelement information being used for instructing the terminal device todisplay the target interpretation element when the terminal devicedisplays the route planning result.

According to a second aspect, an embodiment of this application providesa route display method, performed by a terminal device, the methodincluding:

transmitting a route planning request for a route planning mode to aserver, the route planning mode being used for identifying a reason forinitiating the route planning request;

obtaining element information returned by the server, the elementinformation including an element identifier, the element identifierbeing used for instructing to display a target interpretation elementwhen the terminal device displays a route planning result;

determining the target interpretation element from a locally-savedinterpretation resource pool according to the element identifierincluded in the element information; and

displaying the target interpretation element when a route planningresult corresponding to the route planning request is displayed.

According to a third aspect, an embodiment of this application providesa route display apparatus, the apparatus including: a first determiningunit, a second determining unit, a third determining unit and a fourthdetermining unit;

the first determining unit being configured to determine a correspondingroute planning result and original interpretation data according to aroute planning request for a route planning mode, the route planningmode being used for identifying a reason for initiating the routeplanning request;

the second determining unit being configured to determine acorresponding target interpretation template according to the routeplanning mode and a route interpretation scenario corresponding to theoriginal interpretation data;

the third determining unit being configured to determine elementinformation according to the original interpretation data and the targetinterpretation template, the element information including an elementidentifier of a target interpretation element corresponding to the routeplanning result; and

the fourth determining unit being configured to transmit the elementinformation to the terminal device, the element identifier in theelement information being used for instructing the terminal device todisplay the target interpretation element when the terminal devicedisplays the route planning result.

According to a fourth aspect, an embodiment of this application providesa route display apparatus, the apparatus including: a transmitting unit,an obtaining unit, a determining unit and a display unit:

the transmitting unit being configured to transmit a route planningrequest for a route planning mode to a server, the route planning modebeing used for identifying a reason for initiating the route planningrequest;

the obtaining unit being configured to obtain element informationreturned by the server, the element information including an elementidentifier, the element identifier being used for instructing to displaya target interpretation element when the terminal device displays aroute planning result;

the determining unit being configured to determine the targetinterpretation element from a locally-saved interpretation resource poolaccording to the element identifier included in the element information;and

the display unit being configured to display the target interpretationelement when a route planning result corresponding to the route planningrequest is displayed.

According to a fifth aspect, an embodiment of this application providesa computer device, the device including a processor and a memory:

the memory being configured to store program code and transmit theprogram code to the processor; and

the processor being configured to perform the method described in theforegoing first aspect or the second aspect according to instructions inthe program code.

According to a sixth aspect, an embodiment of this application providesa non-transitory computer-readable storage medium, the computer-readablestorage medium being configured to store a computer program, thecomputer program being configured to perform the method described in theforegoing first aspect or the second aspect.

According to a seventh aspect, an embodiment of this applicationprovides a computer program product or a computer program, the computerprogram product or the computer program including computer instructions,the computer instructions being stored in a computer-readable storagemedium. A processor of a computer device reads the computer instructionsfrom the computer-readable storage medium, and the processor executesthe computer instructions, to cause the computer device to perform themethod described in the foregoing first aspect or the second aspect.

According to an eighth aspect, an embodiment of this applicationprovides a route display system, the system including a terminal deviceand a server, the server being configured to perform the methoddescribed in the foregoing first aspect, and the terminal device beingconfigured to perform the method described in the foregoing secondaspect.

It can be seen from the foregoing technical solutions that when theroute planning request for the route planning mode is obtained, thecorresponding route planning result and the original interpretation datathat may be involved in the current route planning result can bedetermined, the route interpretation scenario corresponding to theoriginal interpretation data and the route planning mode are used asquery words to query the corresponding target interpretation template,and the target interpretation element that needs to be displayed whenthe terminal device displays the route planning result can be determinedthrough the target interpretation template, where the targetinterpretation element may be configured to explain the route planningresult. The foregoing interpretation templates decouple combinations ofvarious route planning modes and route interpretation scenarios fromeach other, so that maintenance and update may be independentlyperformed, a hard-coding stage in related art is eliminated, onlyinterpretation templates corresponding to the combinations need to beadded when route interpretation scenarios are newly added when routeinterpretation scenarios are newly added, and each independentinterpretation template is also easier to update and maintain. Moreover,even for a new route interpretation scenario, the terminal device cancomplete display of the interpretation element only based on instructionof the element information, which no longer requires cumbersome codingdebugging and logic iteration, freeing up processing resources of theterminal device.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a schematic diagram of an application scenario of a routedisplay method according to an embodiment of this application.

FIG. 2 is a signaling interaction diagram of a route display systemaccording to an embodiment of this application.

FIG. 3 is a framework diagram of a route display system according to anembodiment of this application.

FIG. 4 is a flowchart of updating an interpretation template accordingto an embodiment of this application.

FIG. 5 is a flowchart of updating an interpretation template accordingto an embodiment of this application.

FIG. 6A is a schematic diagram of an application scenario of a routedisplay method according to an embodiment of this application.

FIG. 6B is a schematic diagram of an application scenario of a routedisplay method according to an embodiment of this application.

FIG. 6C is a schematic diagram of an application scenario of a routedisplay method according to an embodiment of this application.

FIG. 7 is a flowchart of an application scenario of a route displaymethod according to an embodiment of this application.

FIG. 8 is a schematic diagram of determining element informationaccording to an embodiment of this application.

FIG. 9 is a framework diagram of displaying a target interpretationelement by a terminal device according to an embodiment of thisapplication.

FIG. 10 is a schematic diagram of a route display apparatus according toan embodiment of this application.

FIG. 11 is a schematic diagram of a route display apparatus according toan embodiment of this application.

FIG. 12 is a schematic diagram of a route display system according to anembodiment of this application.

FIG. 13 is a schematic structural diagram of a server according to anembodiment of this application.

FIG. 14 is a schematic structural diagram of a terminal device accordingto an embodiment of this application.

DESCRIPTION OF EMBODIMENTS

The following describes embodiments of this application with referenceto the accompanying drawings.

In the related art, when a route is displayed in an electronic map,different combinations of route planning modes and route interpretationscenarios correspond to different code logic. With continuous increaseof the route interpretation scenarios and the route planning modes, thecode logic corresponding to the combinations of the two will become moreand more complex. A current manner of displaying a route through hardcoding is not conducive to code maintenance and updating. When a routeinterpretation scenario or a route planning mode is newly added, both aserver and a terminal device need to modify or add relevant protocoldata, then respectively iterate internal logic, and finally jointlydebug and distribute a release. The overall iteration efficiency islower.

To reduce complexity of code logic and improve the iteration efficiency,the embodiments of this application provide a route display method and arelated apparatus.

The route display method provided in the embodiments of this applicationmay be applied to an electronic device with route calculation,processing, and display capabilities, such as a server or a terminaldevice. The method may be independently performed by the server, orindependently performed by the terminal device, and may further beapplied to a network scenario in which the terminal device is incommunication with the server, and is performed by the terminal deviceand the server in a cooperation manner. The terminal device may be asmartphone, a notebook computer, a desktop computer, an in-vehiclecomputer, a personal digital assistant (PDA), a tablet computer, orother devices. The server may be an application server or a Web server.In actual deployment, the server may be an independent physical server,may be a server cluster or distributed system including a plurality ofphysical servers, or may be a cloud server providing cloud computingservices. The terminal and the server may be directly or indirectlyconnected in a wired or wireless communication manner. This is notlimited in this application.

In addition, the technical solutions provided in this applicationfurther relate to the field of cloud technologies, such as a databaseand other fields.

The database, in short, may be considered as an electronic file cabinet,that is, a place for storing electronic files. A user may performoperations such as adding, querying, updating, or deleting data in thefiles. The so-called “database” is a data set that is stored together ina particular manner and can be shared with a plurality of users, has aslittle redundancy as possible, and is independent of an application.

A database management system (DBMS for short) is a computer softwaresystem designed for managing a database, generally having basicfunctions such as storage, interception, security assurance, and backup.The database management system may use a database model it supports forclassification, such as a relational expression and an extensible markuplanguage (XML); or perform classification based on a supported computertype, such as a server cluster and a mobile phone; or performclassification according to a used query language, such as a structuredquery language (SQL) and Xquery; or perform classification according toa performance impulse focus, such as a maximum size and a maximumoperating speed; or perform classification in another manner. Regardlessof the classification manner used, some DBMSs support cross-category,for example, simultaneously supporting a plurality of query languages.

In the embodiments of this application, an interpretation template isstored, queried, modified and synchronized through the database.

To facilitate understanding of the technical solutions of thisapplication, the following describes, with reference to actualapplication scenarios, the route display method provided in theembodiments of this application.

Referring to FIG. 1 , FIG. 1 is a schematic diagram of an applicationscenario of a route display method according to an embodiment of thisapplication. As shown in FIG. 1 , a terminal device 100 and a server 200are included. In this embodiment, mainly taking an example in which theroute display method provided in the embodiment of this application isexecuted by the server 200, a scenario-based introduction is given tothe route display method.

The server 200 receives a route planning request for a route planningmode transmitted by the terminal device 100. The route planning mode isused for identifying a reason for initiating the route planning request.For example, a new route planning request will be triggered due tovarious initiation reasons such as yawing, main and side road switching,user preference changing, and via point adding or removing innavigation.

The server 200 determines a corresponding route planning result andoriginal interpretation data according to the route planning request forthe route planning mode. The server 200 may calculate a correspondingroute planning result based on a starting point and an end point in theroute planning request. The route planning result includes a plannedroute from the starting point to the end point. The originalinterpretation data is interpretation data that may be involved in theplanned route, including a corresponding route interpretation scenario;For example, the route interpretation scenario may be whether theplanned route avoids congestion, passes through mountain roads, avoidsmountain roads, avoids road closures, avoids hard-to-walk paths, or thelike. As shown in FIG. 1 , from a starting point to an end point of thisroute planning, taking driving as a travel mode, a determined routeplanning result includes two routes, respectively being a route A thattakes 6 minutes to travel 1.3 km, and a route B that takes 3 minutes totravel 694 m. Since the route B passes through hard-to-walk paths, theroute A is a recommended route, and the route B is an additionalreference route.

As mentioned above, since the route planning mode may reflect a reasonfor initiating the route planning request, for the same starting pointand end point, different route planning results may be determined basedon different route planning modes. For example, different userpreferences, via point modification, and the like will result indifferent routes being included in the route planning result. Differentroute planning results may require interpretation elements(corresponding to route interpretation scenario) of different types toexplain reasons for such planning.

Further, even if a same route interpretation scenario is determinedbased on the route planning result, interpretation elements thatactually need to be displayed in different route planning modes may bedifferent. For example, for the same route interpretation scenario, aninterpretation element displayed during identification of performingroute planning for the first time may also be different from aninterpretation element displayed in the route planning mode innavigation.

Thus, a corresponding interpretation template may be defined based on acombination of the route planning mode and the route interpretationscenario, and display rules and demands of the interpretation elementunder different combinations may be determined through theinterpretation template.

Thus, the server 200 may determine a target interpretation templatecorresponding to the combination of the route planning mode and theroute interpretation scenario based on the route planning mode and theroute interpretation scenario corresponding to the originalinterpretation data. For example, in the scenario shown in FIG. 1 , theroute planning mode is first-time route planning, and the routeinterpretation scenario corresponding to the original interpretationdata is avoiding hard-to-walk paths. The server 200 may use avoidinghard-to-walk paths and first-time route planning as query words, andquery the database 300 for the target interpretation templatecorresponding to the combination mode.

The server 200 determines element information according to the originalinterpretation data and the target interpretation template, and sendsthe element information to the terminal device 100 as an explanation forthe determined route planning result. The element information includesan element identifier corresponding to the target interpretation elementof the route planning result. The element identifier is used forinstructing to display the target interpretation element when theterminal device 100 displays the route planning result. For example,there is a hard-to-walk path of 549 m on the route B. The targetinterpretation element is an element identifier for interpreting thehard-to-walk path. When the route planning result is displayed, an iconcorresponding to the hard-to-walk path (the character “narrow” in acircle), copywriting (the hard-to-walk path has been avoided for you,549 meters in total), and the like, will be displayed on the route B.Therefore, it is convenient for the user of the terminal device 100 tounderstand the reason why the recommended route of the current routeplanning result is the route A, and the route B is used as an additionalreference route. Thus, the terminal device 100 receives the elementinformation transmitted by the server 200 and displays the elementinformation correspondingly at a position corresponding to the routeplanning result. Even for a new route interpretation scenario, theterminal device 100 can complete display of the interpretation elementonly based on instruction of the element information, which no longerrequires cumbersome coding debugging and logic iteration, freeing upprocessing resources of the terminal device 100.

For different combinations of the route planning modes and the routeinterpretation scenarios, the technical solutions of this application nolonger implement corresponding code logic in a hard-coding manner, butpre-store different combinations in the form of different interpretationtemplates, so that the combinations of various route planning modes androute interpretation scenarios are decoupled from each other, therebyindependently maintaining and updating. In addition, if a routeinterpretation scenario is newly added, only interpretation templates ofcorresponding combinations need to be added, and each independentinterpretation template is also easier to update and maintain.

Referring to FIG. 2 , FIG. 2 is a signaling interaction diagram of aroute display system according to an embodiment of this application. Asshown in FIG. 2 , the route display system includes a terminal deviceand a server. The terminal device is mainly configured to implementdisplay of a route planning result and a target interpretation element.The server is mainly configured to implement retrieval of a targetinterpretation template, determination and delivery of elementinformation, and the like.

S201: The terminal device transmits a route planning request for a routeplanning mode.

The terminal device transmits the route planning request to the server,so that the server calculates a corresponding route planning resultaccording to the route planning request. For example, the terminaldevice may transmit the route planning request including a startingpoint, an end point and via points to the server. Correspondingly, theserver can calculate one or more routes passing through the startingpoint, the end point and the via points based on the starting point, theend point and the via points included in the route planning request.

Setting via points is a type of route planning mode. Even if thestarting point and the end point are the same, different route planningresults may be obtained by setting different via points. Therefore, whenthe terminal device transmits the route planning request, the routeplanning request may be transmitted based on the route planning mode inwhich the route planning request is transmitted.

This application does not limit timing of transmitting the routeplanning request. The route planning request may be transmitted inresponse to a user's active triggering, or the route planning requestmay be transmitted based on changes of a position of the terminaldevice, changes of road conditions, periodicity, and other reasons.

The route planning mode has many types. There are usually two timingswhen the terminal device transmits the route planning request to theserver, respectively being, initiating route planning to a designatedstarting point and a designated end point for the first time, andinitiating route planning during navigation. Corresponding totransmitting timings for different route planning requests, the routeplanning modes can be divided into two categories, respectively being ahome plan page mode and an in-navigation mode. The home plan page modeis that the terminal device transmits a route planning request to theserver before traveling, which is used for identifying a reason forinitiating the route planning request before navigation. Thein-navigation mode is that the terminal device transmits a routeplanning request to the server in a progress of navigating, which isused for identifying a reason for initiating the route planning requestduring the navigation. Various subdivided route planning modes arefurther included in the two categories, as shown in Table 1. Forexample, Hint may be a main and side road switching mode in the homeplan page mode, or may be a main and side road switching mode in thein-navigation mode. Ph is a yawing mode in navigation, and the like.

TABLE 1 Route Planning Modes and Corresponding Descriptions BeforeTravel/ Route Planning During Travel Mode Description Home plan page Nilfirst-time route planning mode Hint main and side road switching Fr useractive refreshing Addviapoint adding via points Removeviapoint removingvia points Up Inaccurate starting point Prefchange preference changingrestrictions and license plates In-navigation Hint main and side roadswitching mode Ph yawing Fr user active refreshing Fork accompanied bydivergence points Addviapoint adding via points Removeviapoint removingvia points Routerefresh earthworm refreshing, road condition refreshing,dynamic road changing Prefchange preference changing restrictions andlicense plates

S202: The server determines a corresponding route planning result andoriginal interpretation data according to the route planning request forthe route planning mode.

After the server receives the route planning request for the routeplanning mode transmitted by the terminal device, the correspondingroute planning result can be calculated based on a starting point and anend point included in the route planning request, the route planningmode, and the like. A problem of calculating the route planning resultcan be transformed into a mathematical problem. By setting someobjective functions, for example, one or more objective functions suchas the least time spent on the route, the shortest route distance, andthe least number of traffic lights passing through, combining userpreferences and route features from multiple dimensions, and using deeplearning and other algorithms to train a corresponding rankingrecommendation model, first K route planning results are calculated, andthe first K route planning results are transparently transmitted to theterminal device for displaying to a user. For example, a plurality ofroutes displayed on the first plan page may be the first K routeplanning results calculated through the ranking recommendation model.

When the K route planning results are displayed to the user in the formof routes on a map, one of the routes will become a recommended routeand be displayed in a highlighted form. The remaining (K−1) routes aregenerally additional reference routes and are displayed in darkercolors, so that the user can perform route switching, improving userexperience. As shown in FIG. 1 , two route planning results aredisplayed to the user in the form of routes on the map, respectivelybeing a route A and a route B. The route A is a recommended route, andthe route B is an additional reference route.

For recommended routes, the user sometimes may have some questions, forexample, “The route recommended this time is a bit detoured.”, “Why is afamiliar route not recommended this time?” and the like. When the userfinds the recommended routes incomprehensible, a certain exclusionpsychological may occur, for example, “Obviously, both distance and timeare short if taking a high-speed route, so why a high-speed route is notplanned? Is there a problem with the navigation? I won't use it nexttime.”, and the like. The server may not only determine a correspondingroute planning result, but also determine original interpretation dataaccording to the route planning request for the route planning mode. Theoriginal interpretation data is data used for interpreting problems thatmay be involved in the planned route, for example, “The planned route isa bit detoured because it avoids congestion or hard-to-walk paths.”, “Afamiliar route is not recommended due to construction of a roadsection”, “A high-speed route having a short distance and taking a shorttime is not recommended due to highway closures”, and the like. The usercan trust the recommended routes through the original interpretationdata, thereby improving the user's navigation participation andcompletion.

S203: Determine a corresponding target interpretation template accordingto the route planning mode and a route interpretation scenariocorresponding to the original interpretation data.

To make the route planning results combined with the originalinterpretation data more intuitive and easier for the user tounderstand, some interpretation elements may be added when the routeplanning results are displayed, such as icons and copywriting, so thatmore interpretation information can be displayed in a limited interfacedisplay range of the terminal device. The original interpretation dataincludes a corresponding route interpretation scenario. For example, theroute interpretation scenario may be whether the planned route avoidscongestion, passes through mountain roads, avoids mountain roads, avoidsroad closures, avoids hard-to-walk paths, or the like.

Different route interpretation scenarios may require interpretationelements of different types for interpretation, and even for the samestarting point and end point, different route planning results may beobtained based on different route planning modes. Correspondingly,different interpretation elements of different types are required forinterpretation. Thus, the corresponding target interpretation templatemay be jointly determined through the route planning mode and the routeinterpretation scenario, and the required interpretation element isobtained. Content of the interpretation template mainly defines somecontrol items required for the interpretation element. For example, thecontrol items may be information such as whether to present a relevantinterpretation element, default copywriting content, a priority and astyle value. By modifying control items for changing the interpretationtemplate, the interpretation element required for different combinationscan be flexibly configured, and there is no need for both the server andthe terminal device to modify or add relevant protocol data. Inaddition, removing cumbersome coding and debugging, logic iteration andother stages can achieve an effect of rapid iteration. The content ofthe interpretation template and corresponding description are shown inTable 2.

TABLE 2 Content of the Interpretation Template and CorrespondingDescription Field Description Field Description Need_tips whether tipsare Need_marker whether a marker is presented presented Tips_icon a tipsicon Marker_icon a marker icon Tips_title prompting a defaultMarker_priority marking a priority title Tips_content prompting defaultMarker_disappear marking a disappearance content Tips_priority promptinga priority Marker_cloud_key marking a style value Tips_cloud_keyprompting a style Marker_clickable marking whether it is value clickableNeed_bubble whether a bubble is Need_line whether a line is presentedpresented Bubble_content bubble content Line_cloud_key a line stylevalue Bubble_icon a bubble icon Line_priority a line priorityBubble_cloud_key a bubble style value Need_area whether an area ispresent Bubble_priority a bubble priority Area_cloud_key an area stylevalue Bubble_disappear a bubble Area_priority an area prioritydisappearance

Templating the interpretation elements and presentation manners thereofmakes the server flexibly control the presentation manners of theinterpretation elements, and an implementation logic tends to be unifiedbased on the interpretation templates. In addition, a flexible controlof the presentation manners of the interpretation elements is realized,and a problem that the presentation manner cannot be modified due to areleased version is resolved. In addition, with an increase of the routeinterpretation scenarios and the route planning modes, only theinterpretation templates corresponding to the combinations need to beadded, and each independent interpretation template is also easier toupdate and maintain.

S204: Determine element information according to the originalinterpretation data and the target interpretation template.

The element information includes an element identifier of the targetinterpretation element corresponding to the route planning result. Thetarget interpretation element is a display form of the interpretationelement required for the route planning result. The element identifierof the target interpretation element is an index of the display form inan interpretation resource pool of the terminal device. For example, ifZhang San wants to go to a supermarket, the target interpretationelement may be a prompt indicating whether the supermarket is open ornot. The target interpretation element can be obtained in theinterpretation resource pool by using the element identifiercorresponding to the prompt.

Most content of the element information has already been defined in thetarget interpretation template. When the required element information isconstructed, it is only necessary to calculate whether the elementinformation transmitted to the terminal device is issued, what style,specific copywriting and other information according to the targetinterpretation template and the original interpretation data, therebydetermining a rendering and presentation manner of the elementinformation in the terminal device.

In some special route interpretation scenarios, corresponding specialelement information needs to be obtained from an external service.Referring to FIG. 8 , the figure is a schematic diagram of determiningelement information according to an embodiment of this application.

S801: Obtain original interpretation data.

S802: Obtain a target interpretation template.

S803: Determine element information.

S804: Determine special element information.

In special route interpretation scenarios such as road restrictions androad closures, it is necessary to obtain detailed information of roadrestrictions and road closures by calling an external service accordingto road information where the route interpretation scenario is locatedin the original interpretation data. Then, the corresponding targetinterpretation template is converted into special element informationsuch as restricted lines, restricted areas or road closure prompts.

S205: The server transmits the element information to the terminaldevice.

The server transmits the element information to the terminal device, sothat the terminal device can obtain a target interpretation elementthrough the element information, and then display the targetinterpretation element when the route planning result is displayed.

S206: The terminal device determines a target interpretation elementfrom a locally-saved interpretation resource pool according to theelement information.

After obtaining the element information transmitted by the server, theterminal device searches for the target interpretation element in theinterpretation resource pool according to the element information. Theinterpretation resource pool is stored locally by the terminal device,and the interpretation resource pool includes various element materialsof the elements to be interpreted, and is indexed by the elementidentifier. For example, the element material may be presentationmanners such as background color, font size, spacing of theinterpretation element, and data such as background images and icons.

Thus, the terminal device can determine the required targetinterpretation element through the element information transmitted bythe server without a need for the terminal device to implement relevantlogics such as whether the interpretation element is to be presented,presented in what style, and a presentation priority. The relevantlogics are all implemented in the server. In the terminal device, onlyhow the interpretation element is rendered and presented and overlaylogic needs to be focused on, and which services the element informationis to be obtained from does not need to be focused on, which makes theterminal device more lightweight, thereby simplifying an internalimplementation process of the terminal device and reducing complexity.

S207: The terminal device displays the target interpretation elementwhen a route planning result corresponding to the route planning requestis displayed.

Referring to FIG. 9 , the figure is a framework diagram of displaying atarget interpretation element by a terminal device according to anembodiment of this application. The terminal device can obtain variouselement materials of all interpretation elements in advance. Forexample, when the terminal device starts, various element materials ofall interpretation elements are obtained, and an interpretation resourcepool is formed by using all the element materials and stored locally inthe terminal device for subsequent use.

After the server transmits the element information to the terminal, theterminal device queries a required target interpretation element fromthe interpretation resource pool according to the element information.When the route planning request is displayed, the target interpretationelement is rendered and presented in the route planning result andpresented to a user at the same time.

After the terminal device obtains the target interpretation element, aposition corresponding to the target interpretation element can becalculated according to the route planning result, and the targetinterpretation element is displayed at the corresponding position when aroute planning result corresponding to the route planning request isdisplayed.

It can be seen from the foregoing technical solutions that the terminaldevice obtains the route planning request for the route planning modeand transmits it to the server, and the server can determine thecorresponding route planning result and the original interpretation datathat may be involved in the current route planning result according tothe route planning request for the route planning mode. The routeinterpretation scenario corresponding to the original interpretationdata and the route planning mode are used as query words to query thecorresponding target interpretation template. The target interpretationelement that needs to be displayed when the terminal device displays theroute planning result can be determined through the targetinterpretation template, and the target interpretation element is as anexplanation of the route planning result. Such a manner of determiningthe interpretation templates decouples combinations of various routeplanning modes and route interpretation scenarios from each other, sothat maintenance and update may be independently performed, ahard-coding stage in related art is eliminated, only interpretationtemplates corresponding to the combinations need to be added when routeinterpretation scenarios are newly added, and each independentinterpretation template is also easier to update and maintain. Moreover,even for a new route interpretation scenario, the terminal device cancomplete display of the interpretation element only based on instructionof the element information, which no longer requires cumbersome codingdebugging and logic iteration, freeing up processing resources of theterminal device.

The foregoing technical solutions may be applied to different mapproducts. For example, a map product type may be a mobile phone map, aPangu map software development kit (SDK), a car-connected map, and thelike. The need to interpret route planning results may vary betweendifferent map products, and due to differences in display manners andconfiguration locations, for different map products, even if they arebased on the same route planning mode and route interpretation scenario,interpretation elements to be displayed are likely to differ. Therefore,each independent interpretation template needs to be defined separately.To obtain a target interpretation template corresponding to the routeplanning request transmitted by this map product, relevant informationabout a map product type may be added when the route planning request istransmitted. Thus, the target interpretation template can be jointlydetermined based on three attributes of the route planning mode, theroute interpretation scenario and the map product type. By adding themap product type to determine the target interpretation template,differentiated requirements between different map products can becompleted by modifying or adding interpretation templates, which can notonly allow different map products to independently debug their owntemplates, but also reuse an ability to interpret route planning resultsbetween map products.

For example, when the interpretation template is uniquely determined bythe three attributes of the route planning mode, the routeinterpretation scenario and the map product type, the foregoing tripletcan be defined as a key value of the interpretation template, which isformally defined as: Key=<map product type, route planning mode, routeinterpretation scenario>. For example, some map product types are shownin Table 3, some route planning modes are shown in Table 1, and someroute interpretation scenarios are shown in Table 4. If key isMobile_Nil_0, it means that the map product type is a mobile phone map,the route planning mode is first-time route planning, and the routeinterpretation scenario is avoiding closure.

TABLE 3 Map Product Type and Description Map product type DescriptionMobile mobile phone map Pangu Pangu map software development kit Wecarcar-connected map

TABLE 4 Route Interpretation Scenario and Description Routeinterpretation scenario Description 0 avoiding closure 1 passing throughclosure 2 avoiding congestion

When the route planning result is displayed, the most basic service isto display the route planning result, and based on this, aninterpretation service for the route planning result is furtherrealized. Based on this, the route planning result and the elementinformation may be transmitted to the terminal device in two successivesteps, thereby ensuring that the terminal device can display the routeplanning result even if there is a problem that the element informationcannot be obtained.

After the server determines the route planning result according to theroute planning request, the route planning result is first returned tothe terminal device, so that the terminal device can display the routeplanning result. In addition, the server saves a correspondence betweena route planning identifier (RPID) of the route planning result and theelement information. After the terminal device obtains a route planningresult returned by the server, an interpretation service request can betransmitted to the server according to the route planning identifierincluded in the route planning result. After the server obtains theinterpretation service request, element information corresponding to theroute planning identifier can be retrieved according to the routeplanning identifier included in the interpretation service request andthe previously saved correspondence, to transmit the element informationto the terminal device, so that the terminal device displays the targetinterpretation element when the route planning result is displayed.

The terminal device transmits the route planning request and theinterpretation service request to the server in two steps, so that theserver transmits the results obtained by calling for two times,respectively being the route planning result and the elementinformation, to the terminal device in two steps. When the terminaldevice cannot obtain the element information, the terminal device canstill normally display the route planning result, and the terminaldevice will not be unable to obtain any returned result due to theinability to obtain the element information, ensuring the stability ofthe system and improving a success rate of terminal device display.

To make the technical solutions provided in this application clearer toa person skilled in the art, an embodiment is described below. Referringto FIG. 3 , the figure is a framework diagram of a route display systemaccording to an embodiment of this application.

To separate a route planning service and a route interpretation service,a route planning module and a route interpretation module may beconfigured in the server. The route planning result is returned throughthe route planning module, and the element information is returnedthrough the route interpretation module. Specifically, every time theterminal device transmits a route planning request, the route planningmodule may determine a corresponding route planning result according tothe route planning request. If the route planning result this timeinvolves the original interpretation data, the route planning modulewill generate a route planning identifier corresponding to the routeplanning result, and return the route planning result and itscorresponding route planning identifier to the terminal device.

The route planning module writes the original interpretation datacorresponding to the route planning identifier into an originalinterpretation database. The original interpretation database may be aremote dictionary server (Redis) database. This is not specificallylimited in this application.

After the route interpretation module obtains an interpretation servicerequest transmitted by the terminal device, corresponding originalinterpretation data will be retrieved from the original interpretationdatabase according to the route planning identifier included in theinterpretation service request, and a route planning mode and a routeinterpretation scenario are obtained according to the retrieved originalinterpretation data. The route interpretation module usually obtains allinterpretation templates from the interpretation template library inadvance, and determines a corresponding target interpretation templatefrom all the templates according to the route planning mode and theroute interpretation scenario. The interpretation template library maybe generated and maintained through an external configuration system.

The route interpretation module determines element information accordingto the original interpretation data and the target interpretationtemplate, and transmits the element information to the terminal device.

The interpretation template library is separately split to the externalconfiguration system and is maintained and operated, so that developerscan only focus on how to use the interpretation template to implement aninterpretive internal logic without maintaining specific templatecontent. On the other hand, product and operation personnel can flexiblymodify and change the template content through the externalconfiguration system, and do not have to care about how the templatecontent is used. The system is properly divided by focusing ondifference of the content to achieve an effect of efficientcoordination.

With continual increase of the route planning modes and the routeinterpretation scenarios, the interpretation templates corresponding tothe combinations are also increasing. After the interpretation templateis added or changed with the help of the external configuration system,the updated template data needs to be synchronized to the server,thereby ensuring data consistency. To ensure that the service will notbe interrupted during synchronization, the embodiment of thisapplication may implement the data consistency by using a fulldouble-buffering hot loading manner. The first interpretation templatelibrary and the second interpretation template library are constructedin a server cache. The target interpretation template may be determinedaccording to the interpretation template in the first interpretationtemplate library.

Referring to FIG. 4 , the figure is a flowchart of updating aninterpretation template according to an embodiment of this application.

S410: The server transmits an update request to an interpretationtemplate library server.

For a route planning problem, data consistency may be achieved within aperiod of time. Transmitting the update request to the interpretationtemplate library server at regular intervals may be set in the server,so that data in the interpretation template library can be consistentwith data in the server. Certainly, in practical application, theinterpretation template library can also actively deliver updatedinterpretation templates to the server periodically.

S420: Obtain a second interpretation template library and a templatelibrary digest corresponding to the second interpretation templatelibrary from the interpretation template library server.

The server obtains the second interpretation template library and thetemplate library digest corresponding to the second interpretationtemplate library from the interpretation template library of theinterpretation template library server.

S430: Calculate and obtain a digest according to the secondinterpretation template library.

When the server obtains the second interpretation template library, theobtainment is likely to fail or be incomplete, so that an obtainedsecond interpretation template library is different from theinterpretation template in the interpretation template library. Based onthis, the server may calculate the digest according to the obtainedsecond interpretation template library, and then compare the digest withthe template library digest corresponding to the obtained secondinterpretation template library.

S440: Determine whether the digest is the same as the template librarydigest. If so, perform S450; or if not, perform S460.

S450: If the digest is the same as the template library digest, replacethe first interpretation template library with the second interpretationtemplate library.

If the digest is the same as the template library digest, it means thatcontent of the second interpretation template library is the same ascontent in the interpretation template library, and the firstinterpretation template library can be replaced with the secondinterpretation template library to complete the update.

S460: If the digest is different from the template library digest, endthe updating.

If the digest is different from the template library digest, it meansthat the obtained second interpretation template library may be damaged,and the updating needs to be ended.

Thus, by caching the first interpretation template library and thesecond interpretation template library in a server cache, afterdetermining that the second interpretation template library is the sameas the interpretation template in the interpretation template library,the first interpretation template library will be replaced with thesecond interpretation template library. In the foregoing replacementprocess, the first interpretation template library may continue toprovide the server with an interpretation service for the route planningresult. Therefore, not only data consistency is realized, but also theinterpretation service for the route planning result will not beinterrupted during the realization process.

Since the server does not know whether the interpretation templates inthe interpretation template library are modified or added, to savecomputing resources, whether the second interpretation template libraryis changed can be determined before the second interpretation templatelibrary is obtained. If the second interpretation template library isdifferent from the first interpretation template library, using thesecond interpretation template library to update the firstinterpretation template library. Referring to FIG. 5 , the figure is aflowchart of updating an interpretation template according to anembodiment of this application. S420 can be implemented through S421 toS424, and only S421 to S424 are described below.

S421: Obtain a template library digest corresponding to the secondinterpretation template library from the interpretation target server.

S422: Determine whether the template library digest corresponding to thesecond interpretation template library is the same as a digest of thefirst interpretation template library. If so, perform S460; or if not,perform S423.

S460: If the template library digest corresponding to the secondinterpretation template library is the same as the digest of the firstinterpretation template library, end the updating.

S423: If the template library digest corresponding to the secondinterpretation template library is different from the digest of thefirst interpretation template library, obtain the second interpretationtemplate library from the interpretation template library server.

To better maintain and update the interpretation template and theoriginal interpretation data, interpretation elements in theinterpretation template and the original interpretation data can beprotocolized. For example, a constituent unit of the interpretationelements may be determined based on the type of the interpretationelements, such as point, line and area. Specifically, the constituentunit may be a field such as a line string, a point string, copywriting,and a possible ID list extracted from a combination of the routeplanning mode and the route interpretation scenario. The point stringmay be all possible situations that are involved in point typeinterpretation elements, such as a circle point and a square point. Theserver constructs a route interpretation protocol according to theconstituent unit; and determines the original interpretation databaseand a first interpretation template library including the targetinterpretation template according to the route interpretation protocol.The interpretation elements required for the interpretation template andthe original interpretation data are protocolized through theconstituent unit, and such interpretation elements can be provided in aform of an interface to realize a mutual decoupling between the routeplanning module and the route interpretation module in the server,thereby independently maintaining and updating.

The target interpretation template includes a constituent unit of ainterpretation element, content of the interpretation element, a stylevalue of the interpretation element and a priority of the interpretationelement.

To better understand the route display method provided in the foregoingembodiments, the following describes application scenarios of the routedisplay method provided in the embodiments of this application withreference to FIGS. 6A to 6C and FIG. 7 .

Referring to FIGS. 6A to 6C, FIGS. 6A to 6C are schematic diagrams of anapplication scenario of a route display method according to anembodiment of this application. With reference to the method shown inFIG. 7 , the route display method includes the following steps:

S701: A terminal device transmits a route planning request for afirst-time route planning mode.

As shown in FIG. 6A, after using the terminal device to open a mobilemap application software, a user can enter a designated starting pointand a designated end point in a search box, and choose one of appearancemanners such as taxi, driving, bus and subway, walking and cycling. Theterminal device generates and transmits this route planning request tothe server according to the operation triggered by the user. As shown inFIG. 6A, settings for common travel locations such as home and companyand other settings are further provided on the page, which is convenientfor adding or modifying the route planning modes.

S702: A server determines a corresponding route planning result andoriginal interpretation data according to the route planning request forfirst-time route planning mode.

According to a designated starting point and a designated end point, theserver determines two routes from a starting point to an end point,respectively being a route A: taking 51 minutes to drive, a wholejourney being 26.8 kilometers, and passing through 18 traffic lights,and a route B: taking 47 minutes to drive, a whole journey being 24.6kilometers, and passing through 25 traffic lights. The route planningresult may further involve original interpretation data such as vehiclerestrictions and passenger cars from other cities entering Beijing.

S703: The server transmits the route planning result to the terminaldevice.

The route planning result is first returned to the terminal device topreliminarily ensure that the terminal device can normally display theroute planning result. That is, even if a problem occurs in any of thesteps in S704 to S712, a normal display of the route planning result canstill be guaranteed. As shown in FIG. 6B, it is a schematic diagram ofan interface that only displays the route planning result.

S704: The server determines a corresponding target interpretationtemplate through a mobile map application software, the first-time routeplanning mode, and a corresponding route interpretation scenariocorresponding to the original interpretation data.

A triplet composed of the map product type, the route planning mode andthe route interpretation scenario corresponding to the originalinterpretation data is used as a basis for finding a required targetinterpretation template.

S705: The server determines element information according to theoriginal interpretation data and the target interpretation template.

Information such as whether a target interpretation element ispresented, default copywriting, a priority, a style value is calculatedaccording to the original interpretation data and target templateinterpretation data.

S706: The server saves a correspondence between a route planningidentifier of the route planning result and the element information.

S707: The server obtains an interpretation service request transmittedby the terminal device, and the interpretation service request includesthe route planning identifier of the route planning result.

S708: Retrieve element information corresponding to the route planningidentifier according to the correspondence.

S709: The server transmits the element information to the terminaldevice.

S710: The terminal device determines a target interpretation elementfrom a locally-saved interpretation resource pool according to theelement information.

S711: Calculate a display position corresponding to the targetinterpretation element according to the route planning result.

S712: Display the target interpretation element at the correspondingdisplay position when a route planning result corresponding to the routeplanning request is displayed.

If the system is stable, the target interpretation element may bedisplayed at the corresponding display position. For example, relevantprompts about vehicle restrictions or passenger cars from other citiesentering Beijing are represented through an area type; As shown in FIG.6C, an area covered by a larger surface indicates a vehicle restrictedarea, prompting the vehicle to choose to take a detour or drive straightaccording to a restriction indication. An area covered by a smallersurface indicates that beyond this area is the Beijing area. If thepassenger car from other cities drives out of this area, a Beijing entrypermit for passenger cars from other cities needs to be applied for. Itcan not only be interpreted through the area type interpretationelement, but also can be prompted through copywriting. For example,“On-site application for the Beijing entry permit for passenger carsfrom other cities is temporarily suspended, please apply through the“Beijing Traffic Police” APP in advance” to help the user to make atravel plan. Further, congestion existing in the route can also berepresented through a line type, and the degree of congestion can alsobe shown through different colors.

For the route display method provided in the foregoing embodiment, anembodiment of this application further provides a route displayapparatus.

Referring to FIG. 10 , the figure is a schematic diagram of a routedisplay apparatus according to an embodiment of this application. Theapparatus 1000 includes: a first determining unit 1001, a seconddetermining unit 1002, a third determining unit 1003 and a fourthdetermining unit 1004;

the first determining unit 1001 being configured to determine acorresponding route planning result and original interpretation dataaccording to a route planning request for a route planning mode, theroute planning mode being used for identifying a reason for initiatingthe route planning request;

the second determining unit 1002 being configured to determine acorresponding target interpretation template according to the routeplanning mode and a route interpretation scenario corresponding to theoriginal interpretation data;

the third determining unit 1003 being configured to determine elementinformation according to the original interpretation data and the targetinterpretation template, the element information including an elementidentifier of a target interpretation element corresponding to the routeplanning result; and

-   -   the fourth determining unit 1004 being configured to transmit        the element information to a terminal device, the element        identifier in the element information being used for instructing        to display the target interpretation element when the terminal        device displays the route planning result.

As a possible implementation, the route planning request furtherincludes a map product type associated with the route planning request.The second determining unit 1002 is configured to:

determine the corresponding target interpretation template according tothe map product type, the route planning mode and the routeinterpretation scenario corresponding to the original interpretationdata.

As a possible implementation, the target interpretation template isdetermined from an interpretation template included in a firstinterpretation template library. The apparatus 1000 is furtherconfigured to:

obtain a second interpretation template library and a template librarydigest corresponding to the second interpretation template library froman interpretation template library server;

calculate and obtain a digest according to the second interpretationtemplate library; and

replace the first interpretation template library with the secondinterpretation template library when verification succeeds based on thedigest and the template library digest corresponding to the secondinterpretation template library.

As a possible implementation, the apparatus 1000 is further configuredto:

determine a constituent unit of an interpretation element based on atype of the interpretation element;

construct a route interpretation protocol according to the constituentunit; and

determine the original interpretation data and a first interpretationtemplate library including the target interpretation template accordingto the route interpretation protocol.

As a possible implementation, the target interpretation templateincludes a constituent unit of a interpretation element, content of theinterpretation element, a style value of the interpretation element anda priority of the interpretation element.

As a possible implementation, the apparatus 1000 is further configuredto:

return the route planning result to the terminal device, and save acorrespondence between a route planning identifier of the route planningresult and the element information;

obtain an interpretation service request transmitted by the terminaldevice, the interpretation service request including the route planningidentifier; and

retrieve the element information corresponding to the route planningidentifier according to the correspondence and perform steps oftransmitting the element information to the terminal device.

An embodiment of this application further provides a route displayapparatus. Referring to FIG. 11 , the figure is a schematic diagram of aroute display apparatus according to an embodiment of this application.The apparatus 1100 includes: a transmitting unit 1101, an obtaining unit1102, a determining unit 1103 and a display unit 1104;

the transmitting unit 1101 being configured to transmit a route planningrequest for a route planning mode to a server, the route planning modebeing used for identifying a reason for initiating the route planningrequest;

the obtaining unit 1102 being configured to obtain element informationreturned by the server, the element information including an elementidentifier, the element identifier being used for instructing to displaya target interpretation element when the terminal device displays aroute planning result;

the determining unit 1103 being configured to determine the targetinterpretation element from a locally-saved interpretation resource poolaccording to the element identifier included in the element information;and

the display unit 1104 being configured to display the targetinterpretation element when a route planning result corresponding to theroute planning request is displayed.

As a possible implementation, before the obtaining element informationreturned by the server, the apparatus 1100 is further configured to:

obtain a route planning result returned by the server, the routeplanning result including a corresponding route planning identifier; and

transmit an interpretation service request to the server according tothe route planning identifier to request to obtain the elementinformation from the server.

As a possible implementation, the route planning mode is used foridentifying a reason for initiating route planning before navigation, ora reason for initiating route planning during navigation. Thetransmitting unit 1101 is configured to:

transmit the route planning request to the server when route planning isinitiated for a designated starting point and a designated end point forthe first time, or when the route planning is initiated during thenavigation.

As a possible implementation, the apparatus 1100 is further configuredto:

calculate a display position corresponding to the target interpretationelement according to the route planning result.

The display unit 1104 is configured to:

display the target interpretation element at the display position when aroute planning result corresponding to the route planning request isdisplayed.

An embodiment of this application further provides a route displaysystem. As shown in FIG. 12 , the system 1200 includes a terminal device1201 and a server 1202. The terminal device 1201 is configured toperform the route display method performed by a terminal device side inthe foregoing various embodiments; and the server 1202 is configured toperform the route display method performed by a server side in theforegoing various embodiments.

An embodiment of this application further provides a computer device.The following describes the computer device provided in the embodimentof this application from a perspective of hardware materialization.

Referring to FIG. 13 , FIG. 13 is a schematic structural diagram of aserver according to an embodiment of this application. The server 1300may vary greatly due to different configurations or performance, and mayinclude one or more central processing units (CPUs) 1322 (for example,one or more processors) and a memory 1332, and one or more storage media1330 (for example, one or more mass storage devices) that store anapplication program 1342 or data 1344. The memory 1332 and the storagemedium 1330 may be a transient memory or a persistent memory. A programstored in the storage medium 1330 may include one or more modules (notshown), and each module may include a series of instruction operationsfor the server. Further, the CPU 1322 may be configured to communicatewith the storage medium 1330 to execute a series of instructionoperations in the storage medium 1330 on the server 1300.

The server 1300 may also include one or more power supplies 1326, one ormore wired or wireless network interfaces 1350, one or more input/outputinterfaces 1358, and/or, one or more operating systems 1341 such asWindows Server™, Mac OS X™, Unix™, Linux™, and FreeBSD™.

The steps performed by the server in the foregoing embodiments may bebased on the server structure shown in FIG. 13 .

The CPU 1322 is configured to perform the following operations:

determining a corresponding route planning result and originalinterpretation data according to a route planning request for a routeplanning mode, the route planning mode being used for identifying areason for initiating the route planning request;

determining a corresponding target interpretation template according tothe route planning mode and a route interpretation scenariocorresponding to the original interpretation data;

determining element information according to the original interpretationdata and the target interpretation template, the element informationincluding an element identifier of a target interpretation elementcorresponding to the route planning result; and

transmitting the element information to a terminal device, the elementidentifier in the element information being used for instructing todisplay the target interpretation element when the terminal devicedisplays the route planning result.

In some embodiments, the CPU 1322 may further execute method steps ofany specific implementation manner of the route display method in theembodiment of this application.

For the route display method described above, an embodiment of thisapplication further provides a terminal device used for route display,so that the foregoing route display method can be implemented andapplied in practice.

Referring to FIG. 14 , FIG. 14 is a schematic structural diagram of aterminal device according to an embodiment of this application. For easeof description, only a part related to this embodiment of thisapplication is shown. For a specific technical detail not disclosed,refer to the method part in the embodiments of this application. Theterminal device may be any terminal device including a mobile phone, atablet computer, a personal digital assistant, an in-vehicle terminal,or the like, taking the terminal device being a mobile phone as anexample.

FIG. 14 shows a block diagram of a partial structure of a mobile phonerelated to a terminal device provided in an embodiment of thisapplication. Referring to FIG. 14 , the mobile phone includes: a radiofrequency (RF for short) circuit 1410, a memory 1420, an input unit 1430(including a touch panel 1431 and another input device 1432), a displayunit 1440 (including a display panel 1441), a sensor 1450, an audiocircuit 1460 (may connect a speaker 1461 and a microphone 1462), awireless fidelity (WiFi for short) module 1470, a processor 1480, apower supply 1490, and other components. A person skilled in the art mayunderstand that the mobile phone structure shown in FIG. 14 does notconstitute a limitation to the mobile phone. The mobile phone mayinclude more or fewer components than those shown in the figure, or maycombine some components, or may have different component arrangements.

In an embodiment of this application, the memory 1420 included in themobile phone may store program codes, and transmit the program codes tothe processor.

the processor 1480 included in the terminal device also has thefollowing functions:

transmitting a route planning request for a route planning mode to aserver, the route planning mode being used for identifying a reason forinitiating the route planning request;

obtaining element information returned by the server, the elementinformation including an element identifier, the element identifierbeing used for instructing to display a target interpretation elementwhen the terminal device displays a route planning result;

determining the target interpretation element from a locally-savedinterpretation resource pool according to the element identifierincluded in the element information; and

displaying the target interpretation element when a route planningresult corresponding to the route planning request is displayed.

An embodiment of this application further provides a computer-readablestorage medium, configured to store a computer program, the computerprogram being configured to perform the route display method provided inthe foregoing embodiment.

An embodiment of this application further provides a computer programproduct or a computer program, the computer program product or thecomputer program including computer instructions, the computerinstructions being stored in a computer-readable storage medium. Aprocessor of a computer device reads the computer instructions from thecomputer-readable storage medium, and the processor executes thecomputer instructions, to cause the computer device to perform the routedisplay method provided in the various implementation manners describedabove.

The foregoing descriptions are merely a specific implementation of thisapplication, but are not intended to limit the protection scope of thisapplication. Any variation or replacement readily figured out by aperson skilled in the art within the technical scope disclosed in thisapplication shall fall within the protection scope of this application.Therefore, the protection scope of this application shall be subject tothe protection scope of the appended claims. In this application, theterm “unit” or “module” in this application refers to a computer programor part of the computer program that has a predefined function and workstogether with other related parts to achieve a predefined goal and maybe all or partially implemented by using software, hardware (e.g.,processing circuitry and/or memory configured to perform the predefinedfunctions), or a combination thereof. Each unit or module can beimplemented using one or more processors (or processors and memory).Likewise, a processor (or processors and memory) can be used toimplement one or more modules or units. Moreover, each module or unitcan be part of an overall module that includes the functionalities ofthe module or unit.

What is claimed is:
 1. A route display method performed by a computer device, the method comprising: determining a corresponding route planning result and original interpretation data associated with a route planning request for a route planning mode from a terminal device, the route planning mode being used for identifying a reason for initiating the route planning request; determining a corresponding target interpretation template according to the route planning mode and a route interpretation scenario corresponding to the original interpretation data; determining element information according to the original interpretation data and the target interpretation template, the element information comprising an element identifier of a target interpretation element corresponding to the route planning result; and transmitting the element information to the terminal device, the element identifier in the element information being used for instructing the terminal device to display the target interpretation element when the terminal device displays the route planning result.
 2. The method according to claim 1, wherein the route planning request further comprises a map product type associated with the route planning request, and the determining a corresponding target interpretation template according to the route planning mode and a route interpretation scenario corresponding to the original interpretation data comprises: determining the corresponding target interpretation template according to the map product type, the route planning mode and the route interpretation scenario corresponding to the original interpretation data.
 3. The method according to claim 1, wherein the target interpretation template is determined from an interpretation template comprised in a first interpretation template library, and the method further comprises: obtaining a second interpretation template library and a template library digest corresponding to the second interpretation template library from an interpretation template library server; calculating and obtaining a digest according to the second interpretation template library; and replacing the first interpretation template library with the second interpretation template library when verification succeeds based on the digest and the template library digest corresponding to the second interpretation template library.
 4. The method according to claim 3, wherein the method further comprises: determining a constituent unit of an interpretation element based on a type of the interpretation element; constructing a route interpretation protocol according to the constituent unit; and determining the original interpretation data and a first interpretation template library comprising the target interpretation template according to the route interpretation protocol.
 5. The method according to claim 4, wherein the target interpretation template comprises a constituent unit of an interpretation element, content of the interpretation element, a style value of the interpretation element and a priority of the interpretation element.
 6. The method according to claim 5, wherein the method further comprises: returning the route planning result to the terminal device, and saving a correspondence between a route planning identifier of the route planning result and the element information; obtaining an interpretation service request transmitted by the terminal device, the interpretation service request comprising the route planning identifier; and retrieving the element information corresponding to the route planning identifier according to the correspondence and performing operations of transmitting the element information to the terminal device.
 7. A computer device comprising a processor and a memory: the memory being configured to store program code; and the processor being configured to execute the program code to perform a route display method including: determining a corresponding route planning result and original interpretation data associated with a route planning request for a route planning mode from a terminal device, the route planning mode being used for identifying a reason for initiating the route planning request; determining a corresponding target interpretation template according to the route planning mode and a route interpretation scenario corresponding to the original interpretation data; determining element information according to the original interpretation data and the target interpretation template, the element information comprising an element identifier of a target interpretation element corresponding to the route planning result; and transmitting the element information to the terminal device, the element identifier in the element information being used for instructing the terminal device to display the target interpretation element when the terminal device displays the route planning result.
 8. The computer device according to claim 7, wherein the route planning request further comprises a map product type associated with the route planning request, and the determining a corresponding target interpretation template according to the route planning mode and a route interpretation scenario corresponding to the original interpretation data comprises: determining the corresponding target interpretation template according to the map product type, the route planning mode and the route interpretation scenario corresponding to the original interpretation data.
 9. The computer device according to claim 7, wherein the target interpretation template is determined from an interpretation template comprised in a first interpretation template library, and the method further comprises: obtaining a second interpretation template library and a template library digest corresponding to the second interpretation template library from an interpretation template library server; calculating and obtaining a digest according to the second interpretation template library; and replacing the first interpretation template library with the second interpretation template library when verification succeeds based on the digest and the template library digest corresponding to the second interpretation template library.
 10. The computer device according to claim 9, wherein the method further comprises: determining a constituent unit of an interpretation element based on a type of the interpretation element; constructing a route interpretation protocol according to the constituent unit; and determining the original interpretation data and a first interpretation template library comprising the target interpretation template according to the route interpretation protocol.
 11. The computer device according to claim 10, wherein the target interpretation template comprises a constituent unit of an interpretation element, content of the interpretation element, a style value of the interpretation element and a priority of the interpretation element.
 12. The computer device according to claim 11, wherein the method further comprises: returning the route planning result to the terminal device, and saving a correspondence between a route planning identifier of the route planning result and the element information; obtaining an interpretation service request transmitted by the terminal device, the interpretation service request comprising the route planning identifier; and retrieving the element information corresponding to the route planning identifier according to the correspondence and performing operations of transmitting the element information to the terminal device.
 13. A non-transitory computer-readable storage medium storing a computer program that, when executed by a processor of a computer device, causes the computer device to perform a route display method including: determining a corresponding route planning result and original interpretation data associated with a route planning request for a route planning mode from a terminal device, the route planning mode being used for identifying a reason for initiating the route planning request; determining a corresponding target interpretation template according to the route planning mode and a route interpretation scenario corresponding to the original interpretation data; determining element information according to the original interpretation data and the target interpretation template, the element information comprising an element identifier of a target interpretation element corresponding to the route planning result; and transmitting the element information to the terminal device, the element identifier in the element information being used for instructing the terminal device to display the target interpretation element when the terminal device displays the route planning result.
 14. The non-transitory computer-readable storage medium according to claim 13, wherein the route planning request further comprises a map product type associated with the route planning request, and the determining a corresponding target interpretation template according to the route planning mode and a route interpretation scenario corresponding to the original interpretation data comprises: determining the corresponding target interpretation template according to the map product type, the route planning mode and the route interpretation scenario corresponding to the original interpretation data.
 15. The non-transitory computer-readable storage medium according to claim 13, wherein the target interpretation template is determined from an interpretation template comprised in a first interpretation template library, and the method further comprises: obtaining a second interpretation template library and a template library digest corresponding to the second interpretation template library from an interpretation template library server; calculating and obtaining a digest according to the second interpretation template library; and replacing the first interpretation template library with the second interpretation template library when verification succeeds based on the digest and the template library digest corresponding to the second interpretation template library.
 16. The non-transitory computer-readable storage medium according to claim 15, wherein the method further comprises: determining a constituent unit of an interpretation element based on a type of the interpretation element; constructing a route interpretation protocol according to the constituent unit; and determining the original interpretation data and a first interpretation template library comprising the target interpretation template according to the route interpretation protocol.
 17. The non-transitory computer-readable storage medium according to claim 16, wherein the target interpretation template comprises a constituent unit of an interpretation element, content of the interpretation element, a style value of the interpretation element and a priority of the interpretation element.
 18. The non-transitory computer-readable storage medium according to claim 17, wherein the method further comprises: returning the route planning result to the terminal device, and saving a correspondence between a route planning identifier of the route planning result and the element information; obtaining an interpretation service request transmitted by the terminal device, the interpretation service request comprising the route planning identifier; and retrieving the element information corresponding to the route planning identifier according to the correspondence and performing operations of transmitting the element information to the terminal device. 